package com.amc.dto;

import java.io.Serializable;

public class FoodView implements Serializable{

	private static final long serialVersionUID = -1423713905280120755L;

	private String orderFoodId;
	
	private String foodId;

	private String foodName;

	private double foodPrice;

	private String foodPic;

	private String foodTypeId;
	
	private long count;

	public FoodView(String orderFoodId, String foodId, String foodName,
			double foodPrice, String foodPic, String foodTypeId, long count) {
		super();
		this.orderFoodId = orderFoodId;
		this.foodId = foodId;
		this.foodName = foodName;
		this.foodPrice = foodPrice;
		this.foodPic = foodPic;
		this.foodTypeId = foodTypeId;
		this.count = count;
	}

	public FoodView() {
		super();
	}

	public String getOrderFoodId() {
		return orderFoodId;
	}

	public void setOrderFoodId(String orderFoodId) {
		this.orderFoodId = orderFoodId;
	}

	public String getFoodId() {
		return foodId;
	}

	public void setFoodId(String foodId) {
		this.foodId = foodId;
	}

	public String getFoodName() {
		return foodName;
	}

	public void setFoodName(String foodName) {
		this.foodName = foodName;
	}

	public double getFoodPrice() {
		return foodPrice;
	}

	public void setFoodPrice(double foodPrice) {
		this.foodPrice = foodPrice;
	}

	public String getFoodPic() {
		return foodPic;
	}

	public void setFoodPic(String foodPic) {
		this.foodPic = foodPic;
	}

	public String getFoodTypeId() {
		return foodTypeId;
	}

	public void setFoodTypeId(String foodTypeId) {
		this.foodTypeId = foodTypeId;
	}

	public long getCount() {
		return count;
	}

	public void setCount(long count) {
		this.count = count;
	}

	@Override
	public String toString() {
		return "FoodView [orderFoodId=" + orderFoodId + ", foodId=" + foodId
				+ ", foodName=" + foodName + ", foodPrice=" + foodPrice
				+ ", foodPic=" + foodPic + ", foodTypeId=" + foodTypeId
				+ ", count=" + count + "]";
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + (int) (count ^ (count >>> 32));
		result = prime * result + ((foodId == null) ? 0 : foodId.hashCode());
		result = prime * result
				+ ((foodName == null) ? 0 : foodName.hashCode());
		result = prime * result + ((foodPic == null) ? 0 : foodPic.hashCode());
		long temp;
		temp = Double.doubleToLongBits(foodPrice);
		result = prime * result + (int) (temp ^ (temp >>> 32));
		result = prime * result
				+ ((foodTypeId == null) ? 0 : foodTypeId.hashCode());
		result = prime * result
				+ ((orderFoodId == null) ? 0 : orderFoodId.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		FoodView other = (FoodView) obj;
		if (count != other.count)
			return false;
		if (foodId == null) {
			if (other.foodId != null)
				return false;
		} else if (!foodId.equals(other.foodId))
			return false;
		if (foodName == null) {
			if (other.foodName != null)
				return false;
		} else if (!foodName.equals(other.foodName))
			return false;
		if (foodPic == null) {
			if (other.foodPic != null)
				return false;
		} else if (!foodPic.equals(other.foodPic))
			return false;
		if (Double.doubleToLongBits(foodPrice) != Double
				.doubleToLongBits(other.foodPrice))
			return false;
		if (foodTypeId == null) {
			if (other.foodTypeId != null)
				return false;
		} else if (!foodTypeId.equals(other.foodTypeId))
			return false;
		if (orderFoodId == null) {
			if (other.orderFoodId != null)
				return false;
		} else if (!orderFoodId.equals(other.orderFoodId))
			return false;
		return true;
	}
	

	
	
	
	
	
}
